import request from '@/utils/request'

// 查询物资接收列表
export function listReceipt(query) {
  return request({
    url: '/system/aid/receipt/list',
    method: 'get',
    params: query
  })
}

// 查询物资接收详细
export function getReceipt(receiptId) {
  return request({
    url: '/system/aid/receipt/' + receiptId,
    method: 'get'
  })
}

// 新增物资接收
export function addReceipt(data) {
  return request({
    url: '/system/aid/receipt',
    method: 'post',
    data: data
  })
}

// 修改物资接收
export function updateReceipt(data) {
  return request({
    url: '/system/aid/receipt',
    method: 'put',
    data: data
  })
}

// 删除物资接收
export function delReceipt(receiptId) {
  return request({
    url: '/system/aid/receipt/' + receiptId,
    method: 'delete'
  })
}

// 根据状态查询接收记录
export function getReceiptByStatus(status) {
  return request({
    url: '/system/aid/receipt/status/' + status,
    method: 'get'
  })
}

// 导出物资接收
export function exportReceipt(query) {
  return request({
    url: '/system/aid/receipt/export',
    method: 'get',
    params: query
  })
} 